package com.eight.clienthome.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.eight.clienthome.dao.ShouCangTeacherDao;
import com.eight.clienthome.service.AttentionTeacherService;
import com.eight.clienthome.vo.AttentionVo;
import com.eight.common.pojo.TbShoucangTeacher;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author 向文豪
 * @program: eight-education-parent
 * @description:
 * @date 2023/6/5 15:59
 */
@Service
public class AttentionTeacherServiceImpl implements AttentionTeacherService {
    @Autowired
    private ShouCangTeacherDao shouCangTeacherDao;
    @Override
    public Integer deleteAttention(AttentionVo attentionVo) {

        QueryWrapper<TbShoucangTeacher> wrapper = new QueryWrapper<>();
        wrapper.eq("teacher_id",attentionVo.getTeacherId());
        wrapper.eq("member_id",attentionVo.getMemberId());
        int delete = shouCangTeacherDao.delete(wrapper);
        return delete;
    }



}
